Release Date: Dec. 23, 2016
Note: The release you are looking at is Python 3.6.0, the initial feature release for the legacy 3.6 series which has now reached end-of-life and is no longer supported. See the downloads page for currently supported versions of Python. The final source-only security fix release for 3.6 was 3.6.15 and the final bugfix release was 3.6.8.
Among the new major new features in Python 3.6 were:
Important Information displayed during installation; this information is also available after installation by clicking on /Applications/Python 3.6/ReadMe.rtf. There is important information there about changes in the 3.6.0 installer-supplied Python, particularly with regard to SSL certificate validation.Editors
Elvis Pranskevichus [elvis@magic.io](mailto:elvis@magic.io), Yury Selivanov [yury@magic.io](mailto:yury@magic.io)
This article explains the new features in Python 3.6, compared to 3.5. Python 3.6 was released on December 23, 2016. For full details, see the changelog.
See also PEP 494 - Python 3.6 Release Schedule
New syntax features:
New library modules:
CPython implementation improvements:
**kwargs now corresponds to the order in which keyword arguments were passed to the function.Significant improvements in the standard library:
asyncio module has received new features, significant usability and performance improvements, and a fair amount of bug fixes. Starting with Python 3.6 the asyncio module is no longer provisional and its API is considered stable.datetime module has gained support for Local Time Disambiguation.typing module received a number of improvements.tracemalloc module has been significantly reworked and is now used to provide better output for ResourceWarning as well as provide better diagnostics for memory allocation errors. See the PYTHONMALLOC section for more information.Security improvements:
secrets module has been added to simplify the generation of cryptographically strong pseudo-random numbers suitable for managing secrets such as account authentication, tokens, and similar.os.urandom() now blocks until the system urandom entropy pool is initialized to increase the security. See the PEP 524 for the rationale.hashlib and ssl modules now support OpenSSL 1.1.0.ssl module have been improved.hashlib module received support for the BLAKE2, SHA-3 and SHAKE hash algorithms and the scrypt() key derivation function.Windows improvements:
py.exe launcher, when used interactively, no longer prefers Python 2 over Python 3 when the user doesn’t specify a version (via command line arguments or a config file). Handling of shebang lines remains unchanged - “python” refers to Python 2 in that case.python.exe and pythonw.exe have been marked as long-path aware, which means that the 260 character path limit may no longer apply. See removing the MAX_PATH limitation for details.._pth file can be added to force isolated mode and fully specify all search paths to avoid registry and environment lookup. See the documentation for more information.python36.zip file now works as a landmark to infer PYTHONHOME. See the documentation for more information.Release Date: Sept. 13, 2015
Python 3.5 has reached end-of-life. Python 3.5.10, the final release of the 3.5 series, is available here.
Python 3.5.0 was released on September 13th, 2015.
Among the new major new features and changes in the 3.5 release series are
For more detailed information, please read What's New In Python 3.5.
Editors: Elvis Pranskevichus elvis@magic.io, Yury Selivanov yury@magic.io
This article explains the new features in Python 3.5, compared to 3.4. Python 3.5 was released on September 13, 2015. See the changelog for a full list of changes.
See also
PEP 478 - Python 3.5 Release Schedule
New syntax features:
a @ b.New library modules:
New built-in features:
bytes % args, bytearray % args: PEP 461 – Adding % formatting to bytes and bytearray.bytes.hex(), bytearray.hex() and memoryview.hex() methods. (Contributed by Arnon Yaari in bpo-9951.)memoryview now supports tuple indexing (including multi-dimensional). (Contributed by Antoine Pitrou in bpo-23632.)gi_yieldfrom attribute, which returns the object being iterated by yield from expressions. (Contributed by Benno Leslie and Yury Selivanov in bpo-24450.)RecursionError exception is now raised when maximum recursion depth is reached. (Contributed by Georg Brandl in bpo-19235.)CPython implementation improvements:
LC_TYPE locale is the POSIX locale (C locale), sys.stdin and sys.stdout now use the surrogateescape error handler, instead of the strict error handler. (Contributed by Victor Stinner in bpo-19977.).pyo files are no longer used and have been replaced by a more flexible scheme that includes the optimization level explicitly in .pyc name. (See PEP 488 overview.)Significant improvements in the standard library:
collections.OrderedDict is now implemented in C, which makes it 4 to 100 times faster.ssl module gained support for Memory BIO, which decouples SSL protocol handling from network IO.os.scandir() function provides a better and significantly faster way of directory traversal.functools.lru_cache() has been mostly reimplemented in C, yielding much better performance.subprocess.run() function provides a streamlined way to run subprocesses.traceback module has been significantly enhanced for improved performance and developer convenience.Security improvements:
ssl.SSLContext manually. (See bpo-22638 for more details; this change was backported to CPython 3.4 and 2.7.)Windows improvements:
Please read on for a comprehensive list of user-facing changes, including many other smaller improvements, CPython optimizations, deprecations, and potential porting issues.
Release Date: March 17, 2014
Python 3.4 has reached end-of-life. Python 3.4.10, the final release of the 3.4 series, is available here.
Python 3.4.0 was released on March 16th, 2014.
Python 3.4 includes a range of improvements of the 3.x series, including hundreds of small improvements and bug fixes. Among the new major new features and changes in the 3.4 release series are
Author: R. David Murray rdmurray@bitdance.com (Editor)
This article explains the new features in Python 3.4, compared to 3.3. Python 3.4 was released on March 16, 2014. For full details, see the changelog.
See also PEP 429 – Python 3.4 Release Schedule
New syntax features:
Other new features:
marshal format has been made more compact and efficient (issue 16475).New library modules:
asyncio: New provisional API for asynchronous IO (PEP 3156).ensurepip: Bootstrapping the pip installer (PEP 453).enum: Support for enumeration types (PEP 435).pathlib: Object-oriented filesystem paths (PEP 428).selectors: High-level and efficient I/O multiplexing, built upon the select module primitives (part of PEP 3156).statistics: A basic numerically stable statistics library (PEP 450).tracemalloc: Trace Python memory allocations (PEP 454).Significantly improved library modules:
functools (PEP 443).pickle protocol 4 (PEP 3154).multiprocessing now has an option to avoid using os.fork on Unix (issue 8713).email has a new submodule, contentmanager, and a new Message subclass (EmailMessage) that simplify MIME handling (issue 18891).inspect and pydoc modules are now capable of correct introspection of a much wider variety of callable objects, which improves the output of the Python help() system.ipaddress module API has been declared stableSecurity improvements:
multiprocessing now has an option to avoid using os.fork on Unix. spawn and forkserver are more secure because they avoid sharing data with child processes.multiprocessing child processes on Windows no longer inherit all of the parent’s inheritable handles, only the necessary ones.hashlib.pbkdf2_hmac() function provides the PKCS#5 password-based key derivation function 2.ssl.ssl.ssl.ssl.SSLContext class has a lot of improvements.ssl.match_hostname()) and CRLs (Certificate Revocation lists, see ssl.SSLContext.load_verify_locations()).CPython implementation improvements:
Please read on for a comprehensive list of user-facing changes, including many other smaller improvements, CPython optimizations, deprecations, and potential porting issues.
Release Date: Sept. 29, 2012
Python 3.3 includes a range of improvements of the 3.x series, as well as easier porting between 2.x and 3.x. Major new features in the 3.3 release series are:
yield from)See these resources for further information:
This article explains the new features in Python 3.3, compared to 3.2. Python 3.3 was released on September 29, 2012. For full details, see the changelog.
See also PEP 398 - Python 3.3 Release Schedule
New syntax features:
yield from expression for generator delegation.u'unicode' syntax is accepted again for str objects.New library modules:
faulthandler (helps debugging low-level crashes)ipaddress (high-level objects representing IP addresses and masks)lzma (compress data using the XZ / LZMA algorithm)unittest.mock (replace parts of your system under test with mock objects)venv (Python virtual environments, as in the popular virtualenv package)New built-in features:
Implementation improvements:
importlib.Significantly Improved Library Modules:
Security improvements:
Please read on for a comprehensive list of user-facing changes.
Release Date: Feb. 20, 2011
Note: A newer security-fix release, 3.2.6, is currently available. Its use is recommended.
Python 3.2 was released on February 20th, 2011.
Python 3.2 is a continuation of the efforts to improve and stabilize the Python 3.x line. Since the final release of Python 2.7, the 2.x line will only receive bugfixes, and new features are developed for 3.x only.
Since PEP 3003, the Moratorium on Language Changes, is in effect, there are no changes in Python's syntax and only few changes to built-in types in Python 3.2. Development efforts concentrated on the standard library and support for porting code to Python 3. Highlights are:
See these resources for further information:
Author: Raymond Hettinger
This article explains the new features in Python 3.2 as compared to 3.1. It focuses on a few highlights and gives a few examples. For full details, see the Misc/NEWS file.
See also PEP 392 - Python 3.2 Release Schedule
Release Date: June 26, 2009
Python 3.1 has been superseded by 3.1.1. You can download 3.1.1.
Python 3.1 final was released on June 27th, 2009.
Python 3.1 is a continuation of the work started by Python 3.0, the new backwards-incompatible series of Python. Improvements in this release include:
See these resources for further information:
| Author: | Raymond Hettinger |
|---|---|
| Release: | 3.1.5 |
| Date: | April 09, 2012 |
This article explains the new features in Python 3.1, compared to 3.0.
Release Date: Dec. 3, 2008
Python 3.0 final was released on December 3rd, 2008.
Python 3.0 (a.k.a. "Python 3000" or "Py3k") is a new version of the language that is incompatible with the 2.x line of releases. The language is mostly the same, but many details, especially how built-in objects like dictionaries and strings work, have changed considerably, and a lot of deprecated features have finally been removed. Also, the standard library has been reorganized in a few prominent places.
Here are some Python 3.0 resources:
Please report bugs at http://bugs.python.org
| Author: | Guido van Rossum |
|---|---|
| Release: | 3.0.1 |
| Date: | February 14, 2009 |
This article explains the new features in Python 3.0, compared to 2.6. Python 3.0, also known as “Python 3000” or “Py3K”, is the first ever intentionally backwards incompatible Python release. There are more changes than in a typical release, and more that are important for all Python users. Nevertheless, after digesting the changes, you’ll find that Python really hasn’t changed all that much – by and large, we’re mostly fixing well-known annoyances and warts, and removing a lot of old cruft.
This article doesn’t attempt to provide a complete specification of all new features, but instead tries to give a convenient overview. For full details, you should refer to the documentation for Python 3.0, and/or the many PEPs referenced in the text. If you want to understand the complete implementation and design rationale for a particular feature, PEPs usually have more details than the regular documentation; but note that PEPs usually are not kept up-to-date once a feature has been fully implemented.
Due to time constraints this document is not as complete as it should have been. As always for a new release, the Misc/NEWS file in the source distribution contains a wealth of detailed information about every small thing that was changed.
This section lists those few changes that are most likely to trip you up if you’re used to Python 2.5.
Release Date: July 3, 2010
Note: A bugfix release, 2.7.13, is currently available. Its use is recommended.
Python 2.7.0 was released on July 3rd, 2010.
Python 2.7 is scheduled to be the last major version in the 2.x series before it moves into an extended maintenance period. This release contains many of the features that were first released in Python 3.1. Improvements in this release include:
See these resources for further information:
Author
A.M. Kuchling (amk at amk.ca)
This article explains the new features in Python 2.7. Python 2.7 was released on July 3, 2010.
Numeric handling has been improved in many ways, for both floating-point numbers and for the Decimal class. There are some useful additions to the standard library, such as a greatly enhanced unittest module, the argparse module for parsing command-line options, convenient OrderedDict and Counter classes in the collections module, and many other improvements.
Python 2.7 is planned to be the last of the 2.x releases, so we worked on making it a good release for the long term. To help with porting to Python 3, several new features from the Python 3.x series have been included in 2.7.
This article doesn’t attempt to provide a complete specification of the new features, but instead provides a convenient overview. For full details, you should refer to the documentation for Python 2.7 at https://docs.python.org. If you want to understand the rationale for the design and implementation, refer to the PEP for a particular new feature or the issue on https://bugs.python.org in which a change was discussed. Whenever possible, “What’s New in Python” links to the bug/patch item for each change.
Python 2.7 is the last major release in the 2.x series, as the Python maintainers have shifted the focus of their new feature development efforts to the Python 3.x series. This means that while Python 2 continues to receive bug fixes, and to be updated to build correctly on new hardware and versions of supported operated systems, there will be no new full feature releases for the language or standard library.
However, while there is a large common subset between Python 2.7 and Python 3, and many of the changes involved in migrating to that common subset, or directly to Python 3, can be safely automated, some other changes (notably those associated with Unicode handling) may require careful consideration, and preferably robust automated regression test suites, to migrate effectively.
This means that Python 2.7 will remain in place for a long time, providing a stable and supported base platform for production systems that have not yet been ported to Python 3. The full expected lifecycle of the Python 2.7 series is detailed in PEP 373.
Some key consequences of the long-term significance of 2.7 are:
For projects wishing to migrate from Python 2 to Python 3, or for library and framework developers wishing to support users on both Python 2 and Python 3, there are a variety of tools and guides available to help decide on a suitable approach and manage some of the technical details involved. The recommended starting point is the Porting Python 2 Code to Python 3 HOWTO guide.
For Python 2.7, a policy decision was made to silence warnings only of interest to developers by default. DeprecationWarning and its descendants are now ignored unless otherwise requested, preventing users from seeing warnings triggered by an application. This change was also made in the branch that became Python 3.2. (Discussed on stdlib-sig and carried out in bpo-7319.)
In previous releases, DeprecationWarning messages were enabled by default, providing Python developers with a clear indication of where their code may break in a future major version of Python.
However, there are increasingly many users of Python-based applications who are not directly involved in the development of those applications. DeprecationWarning messages are irrelevant to such users, making them worry about an application that’s actually working correctly and burdening application developers with responding to these concerns.
You can re-enable display of DeprecationWarning messages by running Python with the -Wdefault (short form: -Wd) switch, or by setting the PYTHONWARNINGS environment variable to (or ) before running Python. Python code can also re-enable them by calling ."default"``"d"``warnings.simplefilter('default')
The module also automatically reenables deprecation warnings when running tests.unittest
Much as Python 2.6 incorporated features from Python 3.0, version 2.7 incorporates some of the new features in Python 3.1. The 2.x series continues to provide tools for migrating to the 3.x series.
A partial list of 3.1 features that were backported to 2.7:
{1,2,3}{i: i*2 for i in range(3)}with statement.io library, rewritten in C for performance.","memoryview object.importlib module, described below.repr() of a float is shorter in many cases: it’s now based on the shortest decimal string that’s guaranteed to round back to . As in previous versions of Python, it’s guaranteed that recovers .x``x``float(repr(x))``xround() function is also now correctly rounded.PyCapsule type, used to provide a C API for extension modules.PyLong_AsLongAndOverflow() C API function.Other new Python3-mode warnings include:
operator.isCallable() and operator.sequenceIncludes(), which are not supported in 3.x, now trigger warnings.-3 switch now automatically enables the -Qwarn switch that causes warnings about using classic division with integers and long integers.Release Date: Oct. 2, 2008
Python 2.6 (final) was released on October 1st, 2008. There are a huge number of new features, modules, improvements and bug fixes. For information on what's changed, see:
- Andrew Kuchling's guide to What's New in Python 2.6.
- NEWS file contains a listing of everything that's new in each alpha, beta, and release candidate of Python 2.6.
- PEP 361.
Please report bugs at http://bugs.python.org
See also the license.
Author
A.M. Kuchling (amk at amk.ca)
This article explains the new features in Python 2.6, released on October 1 2008. The release schedule is described in PEP 361.
The major theme of Python 2.6 is preparing the migration path to Python 3.0, a major redesign of the language. Whenever possible, Python 2.6 incorporates new features and syntax from 3.0 while remaining compatible with existing code by not removing older features or syntax. When it’s not possible to do that, Python 2.6 tries to do what it can, adding compatibility functions in a future_builtins module and a -3 switch to warn about usages that will become unsupported in 3.0.
Some significant new packages have been added to the standard library, such as the multiprocessing and json modules, but there aren’t many new features that aren’t related to Python 3.0 in some way.
Python 2.6 also sees a number of improvements and bugfixes throughout the source. A search through the change logs finds there were 259 patches applied and 612 bugs fixed between Python 2.5 and 2.6. Both figures are likely to be underestimates.
This article doesn’t attempt to provide a complete specification of the new features, but instead provides a convenient overview. For full details, you should refer to the documentation for Python 2.6. If you want to understand the rationale for the design and implementation, refer to the PEP for a particular new feature. Whenever possible, “What’s New in Python” links to the bug/patch item for each change.
The development cycle for Python versions 2.6 and 3.0 was synchronized, with the alpha and beta releases for both versions being made on the same days. The development of 3.0 has influenced many features in 2.6.
Python 3.0 is a far-ranging redesign of Python that breaks compatibility with the 2.x series. This means that existing Python code will need some conversion in order to run on Python 3.0. However, not all the changes in 3.0 necessarily break compatibility. In cases where new features won’t cause existing code to break, they’ve been backported to 2.6 and are described in this document in the appropriate place. Some of the 3.0-derived features are:
__complex__() method for converting objects to a complex number.except TypeError as excfunctools.reduce() as a synonym for the built-in reduce() function.Python 3.0 adds several new built-in functions and changes the semantics of some existing builtins. Functions that are new in 3.0 such as bin() have simply been added to Python 2.6, but existing builtins haven’t been changed; instead, the future_builtins module has versions with the new 3.0 semantics. Code written to be compatible with 3.0 can do as necessary.from future_builtins import hex, map
A new command-line switch, -3, enables warnings about features that will be removed in Python 3.0. You can run code with this switch to see how much work will be necessary to port code to 3.0. The value of this switch is available to Python code as the boolean variable sys.py3kwarning, and to C extension code as .Py_Py3kWarningFlag
See also The 3xxx series of PEPs, which contains proposals for Python 3.0. PEP 3000 describes the development process for Python 3.0. Start with PEP 3100 that describes the general goals for Python 3.0, and then explore the higher-numbered PEPS that propose specific features.